home *** CD-ROM | disk | FTP | other *** search
/ Planet Source Code Jumbo …e CD Visual Basic 1 to 7 / 1_2002.ISO / Data / Zips / PSC Search20387612001.psc / Hyperlink.bas < prev    next >
Encoding:
BASIC Source File  |  2001-05-31  |  758 b   |  27 lines

  1. Attribute VB_Name = "Hyperlink"
  2. Option Explicit
  3.  
  4. Private Declare Function ShellExecute Lib "shell32.dll" Alias "ShellExecuteA" _
  5.  (ByVal hwnd As Long, ByVal lpOperation As String, ByVal lpFile As String, _
  6.  ByVal lpParameters As String, ByVal lpDirectory As String, ByVal nShowCmd As Long) _
  7.  As Long
  8.  
  9. Public Sub hypFile(frmName As Form, strFile As String)
  10.   '
  11.   Call ShellExecute(frmName.hwnd, "Open", strFile, "", "", 1)
  12.   '
  13. End Sub
  14.  
  15. Public Sub hypURL(frmName As Form, strWebAddress As String)
  16.   '
  17.   Call ShellExecute(frmName.hwnd, "Open", strWebAddress, "", "", 1)
  18.   '
  19. End Sub
  20.  
  21. Public Sub hypEmail(frmName As Form, strEmail As String)
  22.   '
  23.   Call ShellExecute(frmName.hwnd, "Open", ("mailto:" & strEmail), "", "", 1)
  24.   '
  25. End Sub
  26.  
  27.